export default function isDocumentVisible (): boolean {
  if (typeof document !== 'undefined' && typeof document.visibilityState !== 'undefined') {
    return document.visibilityState !== 'hidden'
  }
  // always assume it's visible
  return true
}
